<?php 

function convertUrlQuery($query)
{
    $queryParts = explode('&', $query);
    $params     = array();
    foreach ($queryParts as $param) {
        $item             = explode('=', $param);
        $params[$item[0]] = $item[1];
    }
    return $params;
}

//$directory = '/'.$conf['adminurl'].'/';//定义目录
$parameter = '?vparameter=';
$protocol = ((!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') || $_SERVER['SERVER_PORT'] == 443) ? "https://": "http://";//判断通讯协议
$adminurl = $protocol . $_SERVER['HTTP_HOST'].$parameter.$_SERVER['QUERY_STRING'];//拼接完整url
$arr = parse_url($adminurl);
//echo $adminurl;
//将URL中的参数取出来放到数组里

$arr_query = convertUrlQuery($arr['query']);
if($_SERVER['QUERY_STRING']){
		include $arr_query['vparameter'].'.php'; 
	}else{
		include '404.php'; 
	}